Configuration of the Generic CiA402 Axis
CODESYS SoftMotion provides drivers for various drives. If no specific driver is available for the CiA402 drive which you are using, then you can use the generic CiA402 axis.
However, the compatibility and behavior of the generic axis depend largely on the CiA402 implementation in the respective drive. In practice, it has been shown that different manufacturers interpret the CiA402 standard differently – particularly with regard to error handling and support for limit switches.
Therefore, it cannot be guaranteed that the generic CiA402 axis will always function correctly or completely with a particular drive.
Note
The generic CiA402 driver supports up to 8 axes in case the device description of the drive does not specify a number. Otherwise, the number of axes defined in the device description is supported.
CANopen: The number of possible axes depends on the profiles of the logical devices in the EDS file (1000H
object and 67FFH + X * 800H
, where X
= number of logical devices). For more details, see the CANopen CiA301 standard.
EtherCAT: The number of possible axes depends on the defined CiA402 channels (CoE DS402Channels) in the ESI file.
An adaptation of the EDS or ESI file needs to be done by the device manufacturer.
Objects used when commissioning
When commissioning, the following objects are accessed if they are supported by the device.
Object | Read/Write Access | (M)andatory (O)ptional | Comment |
---|---|---|---|
| Read | M | The lower value has to be 402. Otherwise cancel. |
| Read | O | |
| Read | O | |
| Read | O | |
| Read | O | |
| Read | O | |
| Read | O | |
| Write | If parameter | |
| Write | If parameter | |
| Read | O |
Objects used during operation
The following objects are used during operation depending on the functions used:
0x603F:00
, 0x6040:00
, 0x6041:00
, 0x6060:00
, 0x6061:00
, 0x6062:00
, 0x6064:00
, 0x606B:00
, 0x606C:00
, 0x6074:00
, 0x6077:00
, 0x6078:00
, 0x607C:00
, 0x60B1:00
, 0x60B2:00,
0x60B8:00
0x60B9:00
, 0x60BA:00
, 0x60BB:00
, 0x60BC:00
, 0x60BD:00
, 0x60F4:00
.
Advanced configuration
Important
You need to select the Show generic device configuration views option in the Options: Device editor dialog so that the tab with the parameters is displayed.
You can use the following parameters to fine-tune the flow of the CiA402 state machine.
CiA402 Parameter | Description |
---|---|
|
|
|
Note: If this option is set to |
| Only relevant when
|
| Only relevant when Bit mask of the states for which immediate disabling is turned on.
Example: Assuming |
| Number of cycles which the state machine waits in state |
| Number of cycles which the state machine stays in |
| Number of cycles at the beginning of |
| Number of cycles which the system waits until the drive has executed a state change command. If the drive fails, then the system will switch back to |
|
Note that in any case, the state machine stays in |
|
|
|
|
| This |
|
|
|
|
|
|
|
|
| In state |
| Whether bit 4 of the status word (voltage enabled) needs to be |
| Whether bit 2 of the status word (operation enabled) needs to be |
| The |
| The |
| The |
|
TRUE: The transition from |
Touch Probe
The MC_TouchProbe
function block requires a TRIGGER_REF
as an input. TRIGGER_REF.iTriggerNumber
has the following meaning for the generic CiA402 axis:
TRIGGER_REF.iTriggerNumber | Meaning |
---|---|
0 | Touch probe 1, positive edge |
1 | Touch probe 1, negative edge |
2 | Touch probe 2, positive edge |
3 | Touch probe 2, negative edge |
Error diagnosis: The drive cannot be switched on via MC_Power
The generic axis expects the following bits in the status word in order to return MC_Power.Status = TRUE
:
Bit 0 (ready to switch on)
Bit 1 (switched on)
Bit 2 (operation enabled)
Bit 5 (quick stop)
Bit 12
However, Bit 12 is not set by every drive. If the drive does not set the bit, then the
_bCheckBit12InPositionMode
parameter of the generic axis can be set toFALSE
.